import Loading from './Loading.vue'
import Vue from 'vue'

const LoadingConsrtuctor = Vue.extend(Loading);

const serve=()=>{
	//创建loading
	let loadingInstance = new LoadingConsrtuctor();
	//将组件挂载的制定元素
	loadingInstance.$mount(document.createElement('div'));
	//将组件挂载的元素添加到body元素下
	document.body.appendChild(loadingInstance.$el);
	Vue.nextTick(()=>{
		loadingInstance.isShow=true
	})
	return loadingInstance
}

export default serve;